include("inc.php");
session_start();
$id = $_COOKIE['Prime-id'];
$pass = $_COOKIE['Prime-pass'];
if($id==""){
$id=$_GET['id'];
}
if($id==""){
if(_S == 1){
header("Location: http://www.jhayashida.co.jp/prime/index.php");
}elseif(_S == 0){
header("Location: http://localhost/public/prime/index.php");
}
exit;
}
//MySQLに接続
if(!$conn = mysql_connect(_DB_SERVER,_DB_UID,_DB_PASS)){
die('MySQL接続失敗');
}
//データベースの選択
if(!$sts = mysql_select_db(_DB_NAME,$conn)){
die('テーブル選択失敗');
}
$sqllist="";
$sqllist.="select * from member where id = '$id' group by id";
$mqlist = mysql_query($sqllist,$conn);
if($rec = mysql_fetch_array($mqlist)){
$blogtitle = $rec['blogtitle'];
$ownerskin_id = $rec['skin_id'];
}
?>
$year = $_COOKIE['year'];
if($year == null){
$year = date("Y");
}
$month = $_COOKIE['month'];
if($month == null){
$month = date("n");
}
$move = $_GET['move'];
switch($move){
case -3 ;
$year -= 10;
break;
case -2 ;
$year -= 1;
break;
case -1 ;
$month -= 1;
if($month < 1){ //月が0以下になったときの処理
$month += 12 ;
$year -= 1;
}
break;
case 0 ;
$year = date("Y");
$month = date("n");
break;
case 1 ;
$month += 1;
if($month > 12){ //月が13以上になったときの処理
$month -=12;
$year += 1;
}
break;
case 2 ;
$year += 1;
break;
case 3 ;
$year += 10;
break;
case 4 ;
$year += 100;
break;
}
setcookie("year",$year,time()+60*60);
setcookie("month",$month,time()+60*60);
mb_language("Ja") ;
mb_internal_encoding("JIS") ;
header('content-type: text/html; charset =' ._CHARSET);
?>
マウスだけで簡単に作れる ブログワン
//更新履歴の表示処理
$rireki = _rireki();
echo "$rireki";
?>
<< 年月 >> | SUN |
MON |
TUE |
WED |
THU |
FRI |
SAT |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//グラフの表示位置
$sqllist="";
$sqllist.="select * from diet_aim where id = '$id' ";
$sqllist.="group by id";
$mqlist = mysql_query($sqllist,$conn);
while($rec = mysql_fetch_array($mqlist)){
$D=$rec['Dweight'];
// $Dyear=$rec['Dyear'];
// $Dmonth=$rec['Dmonth'];
// $Dday=$rec['Dday'];
}
$sqllist="";
$sqllist.="select * from diet where id = '$id' ";
$sqllist.="group by artnum order by artnum limit 0,31";
$mqlist = mysql_query($sqllist,$conn);
while($rec = mysql_fetch_array($mqlist)){
$DD[]=$rec['DDweight'];
$dd=$rec['artnum'];
$sqllist2="";
$sqllist2.="select * from album where artnum = '$dd' ";
$sqllist2.="group by artnum order by artnum limit 0,31";
$mqlist2 = mysql_query($sqllist2,$conn);
if($rec2 = mysql_fetch_array($mqlist2)){
$odate[]=$rec2['Odate'];
}
}
?>
体重グラフ(最新の入力データから過去一ヶ月分) |
目標 kg |
> alt=""> |
}?>
|
}?>
|
}?>
|